import http from '../utils/http'
/**
 * @description 查询不同订单状态
 * @param {*} status 
 * @param {*} user_id 
 */
export const reqAlldingdan=(status,user_id)=>{
  return http.get(`/order/alldingdan`,{'status':status,'user_id':user_id})
}
/**
 * @description 查询订单详情
 * @param {*} detail_id 
 * @param {*} user_id 
 */
export const reqOrderdetail=(detail_id,user_id)=>{
  return http.get(`/productdetail/orderdetail`,{'detail_id':detail_id,'user_id':user_id})
}

/**
 * @description 申请退款
 * @param {*} refundApplication 
 */
export const reqTuikuan=(refundApplication)=>{
  return http.post(`/refund/tuikuan`,refundApplication,{
    headers: {
      'Content-Type': 'application/json'
    }
  })
}

/**
 * @description 取消订单
 * @param {*} orderId 
 */
export const cancelOrder=(orderId,status)=>{
  return http.get(`/order/cancelOrder`,{'orderid':orderId,'status':status})
}
